package com.pkk.penguin.frame.know.shiro.shirodemo.springversion.entity.resource;

import com.pkk.penguin.frame.know.shiro.shirodemo.springversion.entity.button.Button;
import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @description:
 * @author: peikunkun
 * @create: 2018-08-29 13:25
 **/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
public class ResourceRole implements Serializable {

  private static final long serialVersionUID = -7420590125499595900L;
  List<ResourceRole> child = new ArrayList<ResourceRole>();
  private Long resourceId;
  private String resourceUrl;
  private String resourceClass;
  private String resourceCode;
  private String resourceName;
  private Integer resourceSort;
  private String resourceType;
  private Long parentResourceId;
  private Integer resourceLevel;
  private List<Button> buttonList;

  public void add(ResourceRole resourceRole) {
    child.add(resourceRole);
  }

}
